import java.util.Iterator;
import java.util.Scanner;
import java.util.TreeSet;

/**
 * <p>明明的随机数去重、排序</p>
 *
 *
 * @author: YuanChilde
 * @date: 2020-02-17 8:01
 * @version: 1.0
 * Modification History:
 * Date    Author      Version     Description
 * -----------------------------------------------------------------
 * 2020-02-17 8:01    YuanChilde     1.0        新增
 */
public class Demo5 {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while(sc.hasNextInt()){
            int count = sc.nextInt();
            TreeSet<Integer> treeSet = new TreeSet();
            for(int i=0;i<count;i++){
                treeSet.add(sc.nextInt());
            }
            Iterator iterator = treeSet.iterator();
            while(iterator.hasNext()){
                System.out.println(iterator.next());
            }
        }
    }
}
